,System.Int32,System.Action{-0})}
SyncLatestIndexedWitness(SyncLatestCoordinatorBase, int, Action) constructor¶
Defined in
Type: SyncLatestIndexedWitnessReactiveUI.Primitives.Async.Advanced
Assembly: ReactiveUI.Primitives.Async.Core.dll
Applies to
net10.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-browserwasm1.0, net9.0-desktop1.0, net8.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-macos14.5, net8.0-tvos17.2, netstandard2.1, net462, net481
public SyncLatestIndexedWitness(SyncLatestCoordinatorBase<TResult> parent, int sourceBit, Action<TSource> recordValue)
Summary:
Per-source WitnessAsync used by every CombineLatestN subscription. The
per-arity class previously declared N hand-rolled OnNextN / OnCompletedN method
pairs whose bodies differed only in which Optional<TN> field they wrote and which
completion bit they passed to the lifecycle. Pre-building N of these witnesses at subscription
time keeps the typing exact and eliminates the per-source method declarations from the per-arity
files. The closure cost (one delegate per source for the value-write) is paid once at subscribe
and not per emission; the actual per-emission cost is one indirect delegate invoke under the
values-lock.
Parameters
| Name | Type | Description |
|---|---|---|
parent | [SyncLatestCoordinatorBase | The parent subscription that owns the values-lock and lifecycle. |
sourceBit | int | The completion bitmask bit owned by this source (1 << index). |
recordValue | Action | Stores the freshly-emitted value into the parent's typed _valN slot. |